package com.example.hqpatrol.entity.response;

import com.xuexiang.xhttp2.model.ApiResult;

public class PatrolResponse<T> extends ApiResult<T> {

    private T page;

    public T getPage() {
        return page;
    }

    public void setPage(T page) {
        this.page = page;
    }

    @Override
    public int getCode() {
        return super.getCode();
    }

    @Override
    public String getMsg() {
        return super.getMsg();
    }

    @Override
    public ApiResult setData(T data) {
        page = data;
        return this;
    }

    @Override
    public T getData() {
        return page;
    }

    @Override
    public boolean isSuccess() {
        return getCode() == 0;
    }
}
